var db = openDatabase('LoginDB', '1.0', 'Login', 2 * 1024 * 1024);
function setWebSQL(e_id,e_log){
	db.transaction(function (tx) {  
	  tx.executeSql('CREATE TABLE IF NOT EXISTS LoginDB (id unique, log)');
	  tx.executeSql('INSERT INTO LoginDB (id,log) VALUES (?, ?)', [e_id, e_log]);
	});
  }
function getWebSQL(){
  db.transaction(function (tx) {
	   tx.executeSql('SELECT * FROM LoginDB', [], function (tx, results) {
		  var len = results.rows.length, i;
		  var msg = "查询记录条数: " + len + "";
		  //document.querySelector('#status').innerHTML +=  msg;
		  for (i = 0; i < len; i++){
			 alert(results.rows.item(i).log );
		  }
	   }, null);
	});
}